<%@ page contentType="text/html; charset=iso-8859-1" language="java" %>
<%@ taglib prefix="c" uri="http://java.sun.com/jsp/jstl/core" %> 
<%@ page import="com.iMusic.businessLogicLayer.Account" %>
<%@ page import="com.iMusic.businessLogicLayer.Product" %>
<!DOCTYPE html PUBLIC "-//W3C//DTD HTML 4.01//EN" "http://www.w3.org/TR/html4/strict.dtd" "http://www.w3.org/TR/html4/frameset.dtd">
<html>
<head>
<meta content="text/html; charset=ISO-8859-1" http-equiv="content-type">
<title>iMusic</title>

<script>


</script>

</head>
<body>
<%
String error=request.getParameter("error");
if(error==null || error=="null"){
 error="";
}

String error2 = (String) request.getSession().getAttribute("Error");
if(error2==null || error2=="null"){
	 error2="";
	}


%>
<%
if (!error2.equals("")) {
%>
	<div style="text-align: right; color: rgb(255, 0, 0);"><%=error2%></div>
<%
}
%>	

Your order history:<br>

<table style="text-align: left; width: 100%; height: 100%;" border="0"
cellpadding="2" cellspacing="2">
<tbody>

<form style="vertical-align: middle; text-align: center; " target="_top" name="Recalculate" onsubmit="return recalculate()" action="RecalculateCart" method="post" >

	<tr>
		<td style="vertical-align: top; width: 100px;"><br>
			<b>ORDER ID</b>
		</td>
		<td style="vertical-align: top; width: 100px;"><br>
			<b>DATE</b>
		</td>
		<td style="vertical-align: top; width: 100px;"><br>
			<b>STATUS</b>
		</td>
		<td style="vertical-align: top; width: 100px;"><br>
			<b>TRACKING<br>NUMBER</b>
		</td>
		<td style="vertical-align: top; width: 100px;"><br>
			<b>LAST<br>MODIFIED</b>
		</td>
		<td style="vertical-align: top; width: 100px;"><br>
			<b>AMOUNT</b>
		</td>
	</tr>


	<c:forEach items="${OrderList}" var="order">
		<tr>
			<td style="vertical-align: top; width: 100px;"><br>
	            ${order.getOrderId()}
	        </td>
			<td style="vertical-align: top; width: 100px;"><br>
	        	${order.getDateCreated()}
	        </td>
			<td style="vertical-align: top; width: 100px;"><br>
	        	${order.getStatus().getName()} 
	        </td>
			<td style="vertical-align: top; width: 100px;"><br>
	        	${order.getTrackingNumber()} 
	        </td>
			<td style="vertical-align: top; width: 100px;"><br>
	        	${order.getDateModified()} 
	        </td>
			<td style="vertical-align: top; width: 100px;"><br>
	        	$${order.getTotal() } 
	        </td>
	    </tr>    
	</c:forEach>

</tbody>
</table>



</body>
</html>